package org.vergil.core.designpattern.vistor;

/**
 * Created by vergil on 17-3-25.
 */
public class Client {
    public static void main(String args[]) {
        EmployeeList list = new EmployeeList();
        AbstractEmployee fte1, fte2, fte3, pte1, pte2;

        fte1 = new FulltimeEmployee("张三", 3200.00, 45);
        fte2 = new FulltimeEmployee("李四", 2000.00, 40);
        fte3 = new FulltimeEmployee("王五", 2400.00, 38);
        pte1 = new ParttimeEmployee("赵六", 80.00, 20);
        pte2 = new ParttimeEmployee("王二", 60.00, 18);

        list.addEmployee(fte1);
        list.addEmployee(fte2);
        list.addEmployee(fte3);
        list.addEmployee(pte1);
        list.addEmployee(pte2);

        AbstractDepartment dep;
        dep = new FADepartment();
        list.accept(dep);
    }
}
